<template>
  <div class="app-container">
    <el-card class="box-card">
      <el-form ref="form" :model="form" >
        <el-descriptions  title="查铺记录基本信息" style="text-align: center" :column="4" border >
          <el-descriptions-item label="姓名" :span="2" label-class-name="my-label" :labelStyle="labelStyle" >{{ form.username}}</el-descriptions-item>
          <el-descriptions-item label="电话" :span="2" label-class-name="my-label" :labelStyle="labelStyle" >{{ form.phone }}</el-descriptions-item>
          <el-descriptions-item label="值班干部" :span="2" label-class-name="my-label" :labelStyle="labelStyle" >{{ form.cadresOnDuty}}</el-descriptions-item>
          <el-descriptions-item label="查铺时间" :span="2" label-class-name="my-label" :labelStyle="labelStyle" >{{ form.checkDate}}</el-descriptions-item>
          <el-descriptions-item label="查铺说明" :span="4" label-class-name="my-label" :labelStyle="labelStyle" >{{ form.checkInstruction }}</el-descriptions-item>
          <el-descriptions-item label="备注" :span="4" label-class-name="my-label" :labelStyle="labelStyle" >{{ form.remark }}</el-descriptions-item>
        </el-descriptions>



      </el-form>
      <br/>
      <div style="float:right; margin-bottom: 15px;">
        <el-button @click="viewCancel">返 回</el-button>
      </div>
    </el-card>
  </div>
</template>
<style>
.img-box1 {
  white-space: pre-wrap;
  width: 90%;

  position: center;
  margin:20px auto;
}
.img-box1 img {
  width: 70%;

  position: relative;
  left: 50%;
  transform: translateX(-50%);
}
.imgpre{
  width:200px;
  height: 100px;


}
.ifr{
  width: 70%;
  height: 700px;

  position: relative;
  left: 50%;
  transform: translateX(-50% );
}


.input_text input.el-input__inner {
  border: none
}

input:disabled{

  background-color: #F5F5F5;

  color:#F5F5F5;
}

</style>
<script>
import { listInspection, getInspection, delInspection, addInspection, updateInspection } from "@/api/module/dfx/inspection";
  import { treeselect } from "@/api/system/dept";
  import Treeselect from "@riophae/vue-treeselect";
  import "@riophae/vue-treeselect/dist/vue-treeselect.css";
  import watermark from "watermark-dom";
  export default {
    name: "File",
    dicts: ['yh_contract_file_type'],
    components: { Treeselect },
    data() {
      return {
        //labelStyle: { 'width': '140px','color': '#000000','text-align': 'right', },
        // 遮罩层
        loading: true,
        // 选中数组
        ids: [],
        // 非单个禁用
        single: true,
        // 非多个禁用
        multiple: true,
        // 显示搜索条件
        showSearch: false,
        // 总条数
        total: 0,
        // 部门树选项
        deptOptions: undefined,
        // 合同资料表格数据
        fileList: [],
        // 弹出层标题
        title: "",
        // 是否显示弹出层
        open: false,
        // 查询参数
        queryParams: {
          pageNum: 1,
          pageSize: 10,
          sequenceNumber: null,
          contractNo: null,
          contractFileName: null,
          contractFileUrl: null,
          contractFileId: null,
          contractFileType: null,
          createBy: null,
          createTime: null,
          updateBy: null,
          updateTime: null,
          remark: null,
          note1: null,
          note2: null,
          note3: null,
          note4: null,
          note5: null,
          note6: null,
          note7: null,
          note8: null,
          note9: null,
          note10: null
        },
        // 表单参数
        form: {},

      };
    },
    mounted() {
      watermark.load({ watermark_txt: "  "   });
    },
    created() {
     const id = this.$route.query.id;
      if (id) {
        // 获取表详细信息
        getInspection(id).then(res => {

          this.form = res.data;

        });

      }
    },
    methods: {
      /** 关闭按钮 */
      viewCancel() {
        const id = this.$route.query.id;
        getInspection(id).then(response => {
          this.form = response.data;

        });
        const obj = {path: "/zonghe/dfxinspection", query: {id}};
        this.$tab.closeOpenPage(obj);

      },

      /** 查询部门下拉树结构 */
      getTreeselect() {
        treeselect().then(response => {
          this.deptOptions = response.data;
        });
      },
    }
  };
</script>
<!--
<style lang="scss" scoped>
  ::v-deep .my-label{
    background: #FFFFFF;
  }

</style>
-->
